import request from '@/utils/request'

// 查询收录信息列表
export function listReceive(query) {
  return request({
    url: '/hcmain/receive/list',
    method: 'get',
    params: query
  })
}

// 查询收录信息详细
export function getReceive(receiveId) {
  return request({
    url: '/hcmain/receive/' + receiveId,
    method: 'get'
  })
}
// 查询库存列表
export function getsel(query) {
  return request({
    url: '/hcmain/receive/list/getsel',
    method: 'get',
    params: query
  })
}
// 查询库存列表
export function alldates() {
  return request({
    url: '/hcmain/receive/alldates',
    method: 'get'
  })
}

// 查询物料列表
export function getstu(query) {
  return request({
    url: '/hcmain/receive/list/getstu',
    method: 'get',
    params: query
  })
}

// 查询物料列表
export function getstuname(query) {
  return request({
    url: '/hcmain/receive/list/getstuname',
    method: 'get',
    params: query
  })
}

// 新增收录信息
export function addReceive(data) {
  return request({
    url: '/hcmain/receive',
    method: 'post',
    data: data
  })
}

// 修改收录信息
export function updateReceive(data) {
  return request({
    url: '/hcmain/receive',
    method: 'put',
    data: data
  })
}

// 删除收录信息
export function delReceive(receiveId) {
  return request({
    url: '/hcmain/receive/' + receiveId,
    method: 'delete'
  })
}
